/**
 * The state of the vending machine. Keeps track of the contents of the vending
 * machine
 * 
 * @author SNelson
 * 
 */
public class VendingMachineState
{
	/**
	 * The number of candy items in the vending machine
	 */
	private final int candyCount;
	/**
	 * The number of cookies in the vending machine
	 */
	private final int cookieCount;

	/**
	 * Constructor
	 * 
	 * @param candyCount
	 *            The number of candy items
	 * @param cookieCount
	 *            The number of cookies
	 */
	public VendingMachineState(int candyCount, int cookieCount)
	{
		this.candyCount = candyCount;
		this.cookieCount = cookieCount;
	}

	/**
	 * Copy constructor
	 * 
	 * @param state
	 *            The state to copy
	 */
	public VendingMachineState(VendingMachineState state)
	{
		this.candyCount = state.getCandyCount();
		this.cookieCount = state.getCookieCount();
	}

	/**
	 * Gets the number of candy items
	 * 
	 * @return The number of candy items
	 */
	public int getCandyCount()
	{
		return candyCount;
	}

	/**
	 * Gets the number of cookies
	 * 
	 * @return The number of cookies
	 */
	public int getCookieCount()
	{
		return cookieCount;
	}
}
